package eleanor.ltd.isRealEstate.entities.roles.group;

import javax.persistence.AssociationOverride;
import javax.persistence.AssociationOverrides;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.apache.tapestry5.beaneditor.NonVisual;

import eleanor.ltd.isRealEstate.entities.pages.action.PagesAction;
import eleanor.ltd.isRealEstate.entities.roles.Roles;

@Entity
@Table(name = "rolesgroup")
public class RolesGroup {
	
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@NonVisual
	@Column(name = "rgid")
	private Long id;
	@ManyToOne(optional = false)
	@JoinColumn(name = "urid")
	private Roles roles;
	@ManyToOne(optional = false)
	@JoinColumn(name = "paid")
	private PagesAction pagesAction;
	
	public Roles getRoles() {
		return roles;
	}
	public void setRoles(Roles roles) {
		this.roles = roles;
	}
	public PagesAction getPagesAction() {
		return pagesAction;
	}
	public void setPagesAction(PagesAction pagesAction) {
		this.pagesAction = pagesAction;
	}
	
}
